#!/usr/bin/env bash

DIR=$(realpath $0) && DIR=${DIR%/*}
cd $DIR
if [ ! -d "conf" ]; then
  echo "miss ./conf"
  exit 1
fi

set -a
. conf/env.sh
set +a
set -ex

bun i

bun x conc --raw \
  "./docker/up.sh" \
  "sleep 2 && node --watch ./srv/srv.js"
